package com.ruoyi.api.po;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.weixin.domain.Client;
import com.ruoyi.weixin.domain.Grade;

import java.util.Date;

public class ClientPo {
    /** id */
    private String clientId;

    /** 性别 0：未知、1：男、2：女 */
    private String gender;

    /** 头像 */
    private String avatarUrl;

    /** 用户名 */
    private String nickName;

    @JsonFormat(pattern="yyyy-MM-dd", locale="zh", timezone="GMT+8")
    private Date birthday;

    /** 邮箱 */
    private String email;

    /** 电话 */
    private String phone;

    /** 状态 */
    private String state;

    /** 等级 */
    private Long gradeId;

    /** 钱 */
    private Long money;

    /** 积分 */
    private Long integral;

    /**
     * 等级
     */
    private Grade grade;

    public ClientPo(){}

    public ClientPo(Client client){
        this.clientId = client.getClientId();
        this.gender = client.getGender();
        this.avatarUrl = client.getAvatarUrl();
        this.nickName = client.getNickName();
        this.email = client.getEmail();
        this.phone = client.getPhone();
        this.state = client.getState();
        this.gradeId = client.getGradeId();
        this.money = client.getMoney();
        this.integral = client.getIntegral();
        this.grade = client.getGrade();
        this.birthday = client.getBirthday();
    }

    public ClientPo(String clientId, String gender, String avatarUrl, String nickName, String email, String phone, String state, Long gradeId, Long money, Long integral, Grade grade) {
        this.clientId = clientId;
        this.gender = gender;
        this.avatarUrl = avatarUrl;
        this.nickName = nickName;
        this.email = email;
        this.phone = phone;
        this.state = state;
        this.gradeId = gradeId;
        this.money = money;
        this.integral = integral;
        this.grade = grade;
    }

    public String getClientId() {
        return clientId;
    }

    public Date getBirthday() {
        return birthday;
    }

    public void setBirthday(Date birthday) {
        this.birthday = birthday;
    }

    public void setClientId(String clientId) {
        this.clientId = clientId;
    }

    public String getGender() {
        return gender;
    }

    public void setGender(String gender) {
        this.gender = gender;
    }

    public String getAvatarUrl() {
        return avatarUrl;
    }

    public void setAvatarUrl(String avatarUrl) {
        this.avatarUrl = avatarUrl;
    }

    public String getNickName() {
        return nickName;
    }

    public void setNickName(String nickName) {
        this.nickName = nickName;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getState() {
        return state;
    }

    public void setState(String state) {
        this.state = state;
    }

    public Long getGradeId() {
        return gradeId;
    }

    public void setGradeId(Long gradeId) {
        this.gradeId = gradeId;
    }

    public Long getMoney() {
        return money;
    }

    public void setMoney(Long money) {
        this.money = money;
    }

    public Long getIntegral() {
        return integral;
    }

    public void setIntegral(Long integral) {
        this.integral = integral;
    }

    public Grade getGrade() {
        return grade;
    }

    public void setGrade(Grade grade) {
        this.grade = grade;
    }
}
